@layout("/common/head.html"){
<body>
<fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
    <legend>表单</legend>
</fieldset>
<form class="layui-form" action="">
    <#input inputName="用户名称" id="userName" name="userName" required="required"/>
    <#input inputName="用户昵称" id="userNick" name="userNick" required="required"/>
    <#input inputName="用户密码" id="userPwd" name="userPwd" required="required"/>
    <#input inputName="用户邮箱" id="userEmail" type="email" name="userEmail" required="required"/>
    <#input inputName="用户电话" id="userMobile" name="userMobile" required="required"/>
    <div class="layui-form-item">
        <label class="layui-form-label">用户角色</label>
        <div class="layui-input-block">
            @if(isNotEmpty(roles)){
                @for(role in roles){
                    <input type="checkbox" name="roleIds" lay-skin="primary" title="${role.name}" value="${role.id}">
                @}
            @}
        </div>
    </div>
    <#select selectName="用户性别" id="userSex" name="userSex" dictType="sex" required="required"/>
    <#select selectName="用户状态" id="status" name="status" list="${status}" optionName="name" optionValue="code" required="required"/>
    <#button btName="添加" filter="add"/>
</form>
<script src="${ctxPath}/static/modules/sys/user/user_add.js"></script>
</body>
@}